<%@ page contentType="text/html;charset=UTF-8" %>
<%@ include file="/WEB-INF/views/include/taglib.jsp"%>
<html>
<head>
	<title>家长关联</title>
	<meta name="decorator" content="default"/>
	<script type="text/javascript">
	$(document).ready(function() {

	});
		function page(n,s){
			if(n) $("#pageNo").val(n);
			if(s) $("#pageSize").val(s);
			$("#searchForm").attr("action","${ctx}/dd/ddParentRelationship/list");
			$("#searchForm").submit();
	    	return false;
	    };
	</script>
</head>
<body>
<div id="importBox" class="hide">
	</div>
	
	<ul class="nav nav-tabs">
	</ul>
	<form:form id="searchForm" modelAttribute="ddParentRelationship" action="${ctx}/dd/ddParentRelationship/" method="post" class="breadcrumb form-search">
		<input id="pageNo" name="pageNo" type="hidden" value="${page.pageNo}"/>
		<input id="pageSize" name="pageSize" type="hidden" value="${page.pageSize}"/>
		<ul class="ul-form">
		</ul>
	</form:form>
	<sys:message content="${message}"/>
	<table id="contentTable" class="table table-striped table-bordered table-condensed">
		<thead>
			<tr>
				<th>家长姓名</th>
				<th>学生姓名</th>
				<!-- <th>家长编号</th>
				<th>学生编号</th> -->
				<th>关系</th>
				<th>备注</th>
				<shiro:hasPermission name="dd:ddParentRelationship:edit"><th>操作</th></shiro:hasPermission>
			</tr>
		</thead>
		<tbody>
		<c:forEach items="${page.list}" var="ddParentRelationship">
			<tr>
				<td><a href="${ctx}/dd/ddParent/form?id=${ddParentRelationship.parentId}" title="查看">
					${ddParentRelationship.parentName}
				</a>
				</td>
				<td>
					${ddParentRelationship.studentName}
				</td> 
				<%-- <td>
					${ddParentRelationship.parentId}
				</td>
				<td>
					${ddParentRelationship.studentId}
				</td> --%>
				<td>
					${fns:getDictLabel(ddParentRelationship.relationship, 'relationship',"")}
				</td>
				<td>
					${ddParentRelationship.remark}
				</td>
				<shiro:hasPermission name="dd:ddParentRelationship:edit">
				<td>
					<a href="javascript:;" href="${ctx}/dd/ddParent/form?id=${ddParentRelationship.parentId}" title="查看家长">查看</a>
    				<a href="javascript:;" href="${ctx}/dd/ddParentRelationship/form?id=${ddParentRelationship.id}" title="修改关联">修改</a>
					<a href="javascript:;" href="${ctx}/dd/ddParentRelationship/delete?id=${ddParentRelationship.id}" onclick="return confirmx('确认要删除该单表吗？', this.href)" title="删除关联">删除</a>
				</td>
				</shiro:hasPermission>
			</tr>
		</c:forEach>
		</tbody>
	</table>
	<div class="pagination">${page}</div>
</body>
</html>